View.TextDecoration

Decoration object that describes visualization properties for text overlays. Note that a viewer might not support all properties.

View.TextDecoration.create()
Return type:

View.TextDecoration

Creates a new TextDecoration.

View.TextDecoration.setBillboardActive(textDecorator, active)
Arguments:
Return type:

View.TextDecoration

Enable billboard mode. Default is off. When active, the text always faces the camera, and setRotation has no effect.

View.TextDecoration.setBounds(textDecorator, width, height)
Arguments:
Return type:

View.TextDecoration

Sets the size of the enclosing bounding box. If set, the text is aligned inside these bounds. The box has its origin at position.

View.TextDecoration.setColor(textDecorator, red, green, blue, alpha)
Arguments:
Return type:

View.TextDecoration

Sets the text color.

View.TextDecoration.setFontFamily(textDecorator, fontFamily)
Arguments:
Return type:

View.TextDecoration

Sets the font style family of the text, e.g., sans serif, mono-spaced or serif font style. Depending on the platform the viewer runs on, a concrete font is selected within the given font family.

View.TextDecoration.setHorizontalAlignment(textDecorator, horizontalAlignment)
Arguments:
Return type:

View.TextDecoration

Sets the horizontal alignment of the text relative to the given text position.

View.TextDecoration.setLineSpacing(textDecorator, lineSpacing)
Arguments:
Return type:

View.TextDecoration

Sets the line spacing in % of the text size.

View.TextDecoration.setPosition(textDecorator, positionX, positionY, positionZ)
Arguments:
Return type:

View.TextDecoration

Sets the text position.

View.TextDecoration.setRotation(textDecorator, rotation, axis)
Arguments:
Return type:

View.TextDecoration

Sets the text rotation in radians around the given text position and around the given axis.

View.TextDecoration.setSize(textDecorator, fontSize)
Arguments:
Return type:

View.TextDecoration

Sets the text font size.

View.TextDecoration.setVerticalAlignment(textDecorator, verticalAlignment)
Arguments:
Return type:

View.TextDecoration

Sets the vertical alignment of the text relative to the given text position.

View.TextDecoration.toString(textDecoration)
Argument:
Return type:

string

Gets a human-friendly string description of the text decoration, containing all properties.